home *** CD-ROM | disk | FTP | other *** search
/ BBS in a Box 7 / BBS in a Box - Macintosh - Volume VII (BBS in a Box) (January 1993).iso / Files / Hyper / I-J / If Monks had Macs....cpt / If Monks had Macs... / Journal / stack_-1.xml < prev    next >
Extensible Markup Language  |  1992-02-09  |  20KB  |  16 lines

  1. <?xml version="1.0" encoding="utf-8" ?>
  2. <!DOCTYPE stack PUBLIC "-//Apple, Inc.//DTD stack V 2.0//EN" "" >
  3. <stack>
  4.     <name>in</name>
  5.     <id>-1</id>
  6.     <cardCount>2</cardCount>
  7.     <cardID>3048</cardID>
  8.     <listID>3592</listID>
  9.     <cantModify><false /></cantModify>
  10.     <cantDelete><true /></cantDelete>
  11.     <cantAbort><false /></cantAbort>
  12.     <cardSize>
  13.         <width>512</width>
  14.         <height>342</height>
  15.     </cardSize>
  16.     <script>on openCardglobal JCardcleanScreenput "Sheet #" &number of this cd & " of " &number of cds ¬¨into bg fld "Sheet"put long name of this cd into JCardif number of this cd <> 1 thenif visible of cd fld "CardInfo" of first cd is true thenhide cd fld "CardInfo" of first cdhide bg btn "Spoiler"put empty into cd fld "CardInfo" of first cdend ifend ifend openCardon idleif textFont of bg fld "Text" is "marker" thenset userLevel to 1hide msgelseset userLevel to 5end ifif commandKey() is down thencancelFindNextshow menuBarend ifif cantmodify of this stack is true thenhide bg btn "Can¬†¬†¬†¬†¬†¬†¬†¬†¬†¬†Modify"end ifend idleon cleanScreenhide menuBarhide messageend cleanScreenon mouseDownIf "button" is not in the target then pass mouseDownif short name of target is not "Find Next" thencancelFindNextend ifend mouseDownon mouseUpif mouseV() <20 and mouseH() < 20 thenshow menuBarelsecleanScreenend ifif "button" is not in the target then pass mouseUpget short name of targetdo itend mouseUpon arrowkey Directionif Direction is "left" thenvisual wipe rightgo prev cdend ifif Direction is "right" thenvisual wipe leftgo next cdend ifif number of this cd is 1 thenplay "Harpsichord"end ifcancelFindNextend arrowkeyon DogEarcleanScreenput (item 3 of rect of target) - (item 1 of clickLoc()) into xput (item 4 of rect of target) - (item 2 of clickLoc()) into yif (x > y) thenif optionKey() is not down thenvisual wipe rightgo previous cdelsevisual wipe rightgo first cdend ifelseif optionKey() is not down thenvisual wipe leftgo next cdelsevisual wipe leftgo last cdend ifend ifif number of this cd is 1 thenplay "Harpsichord"end ifcancelFindNext--David Dunham's, Modified--(Delphi:  DDUNHAM; CIS 76074,762; AppleLink D0457).end DogEaron goBookglobal ICCardset cursor to 3if ICCard is not empty thenelseput "first cd of stack " &quote &"Imitatio Christi" &quote into ICCardend ifvisual zoom ingo ICCardif result() is empty thenelsebeepput empty into ICCardend ifend goBookon CardInfoglobal Mtempset cursor to 3push cdput "card field " &quote &"CardInfo" &quote  into xget (item 2 of clickLoc() - item 2 of rect of x + scroll of x ) div ¬¨textHeight of x + 1lock screenput line it of cd fld "CardInfo" into tester1if tester1 is empty thenvisual wipe rightpop cdelseunlock screenvisual wipe rightgo cd itend ifhide cd fld "CardInfo" of cd 1hide bg btn "Spoiler"put empty into cd fld "CardInfo" of cd 1set cantmodify of this stack to Mtempend CardInfoon doSpoilerglobal Mtempvisual wipe rightpop cdhide cd fld "CardInfo" of cd 1hide bg btn "Spoiler"put empty into cd fld "CardInfo" of cd 1set cantmodify of this stack to Mtempend doSpoileron PAlertanswer "This journal is protected." with "Oh."end PAlert---------------------------Find Stuff------------------------------on searchAC flagglobal whichButton,whichfindbutton,textString,fType,fieldNameif textFont of bg fld "Text" is not "marker" thenif flag >0 thenput SearchAutoCat() into textStringend ifif textString is empty then exit searchACput ",chars,word,whole,string,date" into typeListput item whichButton of typeList into fTypeif fType is "Date" thenfindDateexit searchACend ifif whichFindButton contains 1 then -- search allput empty into fieldNameend if -- wfb 1if whichFindButton contains 2 then -- search sheet numbersput "background field " &kwote(sheet) into fieldNameend if -- wfb 2if whichFindButton contains 3 then -- search text fieldput "background field " &kwote(text) into fieldNameend if -- wfb 3findwkselsePAlertend ifend searchACon FindWksglobal FType,textString,fieldName,hits,doFind,JCardcleanScreencancelFindNextif textstring is not empty thenset cursor to 3lock screenpush cdset lockMessages to truego first cdput collectAllHits(textString,fieldname) into hitsset lockMessages to falseif hits is empty thenpop cdput long name of this cd into JCardunlock screenbeepanswer "Couldn't " &doFindelsego cd (item 1 of hits)put long name of this cd into JCardif number of items in hits > 1 thenshow bg btn "Find Next"end ifclick at 1,1get loc of msgset loc of msg to -1000,-1000put doFindhide msgset loc of msg to itend ifdo doFindend ifend FindWksfunction collectAllHits textString,fieldNameglobal FType,doFindif fieldName is not empty thenput "find " &ftype &" " &kwote(textString) &" in " & fieldName into DoFindelseput "find " &ftype &" " &kwote(textString) into doFindend ifrepeat with i = 1 to 10000 --arbitrarily large numberset cursor to 3do DoFind -- find ftype text in field fieldNameif the result is "not found" then --couldn't find it at allreturn emptyelse if i = 1 then --found it at least onceput id of this cd into firstFind --first time foundput firstFind into hitselse if id of this cd is firstFind then --found it some more times--have come around to first find cardreturn hitselseput "," & id of this cd after hits --add card id to the listend ifset cursor to 3go next cd --start looking from next cardend repeatend collectAllHitson cancelFindNextglobal hitshide bg btn "find next"put empty into hitsend cancelFindNextfunction kwote stringreturn quote & string & quoteend kwoteon FindGoglobal hits,currentNO,dir4set cursor to 3if hits is empty thenelseif hits contains id of this cd thenrepeat with i = 1 to number of items of hitsif item i of hits is id of this cd thenput i into currentNOexit repeatend ifend repeatend ifif dir4 is "left" thenleftGoend ifif dir4 is "right" thenrightGoend ifend ifend FindGoon leftGoglobal hits,currentNOvisual wipe rightif first word of (item (currentNO -1) of hits) is "card" thengo (item (currentNO -1) of hits)elsego item (number of items of hits) of hitsend ifend leftGoon rightGoglobal hits,currentNOvisual wipe leftif currentNO is number of items of hits thengo item 1 of hitselseif first word of (item (currentNO +1) of hits) is "card" thengo (item (currentNO +1) of hits)elsego item (number of items of hits) of hitsend ifend ifend rightGoon FindDateglobal textStringlock screenput empty into tempset cursor to 3if textString is empty then exit FindDaterepeat with i = 1 to number of cds - 1get bg fld "Date" of cd iconvert it to short dateif it is textString thenplay "Harpsichord" "c"unlock screenvisual effect wipe leftgo cd iput i into tempexit FindDateend ifend repeatif temp is empty thenanswer "A card for that date does not exist." with "Cancel"end ifplay "Harpsichord" "f"end FindDate--------------------------End Find Stuff------------------------------on PrintJournalif textFont of bg fld "Text" is not "marker" thenpush cdGo cd 1put cantmodify of this stack into Mtempset cantmodify of this stack to trueset rect of cd fld "Ref" to 82,146,381,220set textSize of cd fld "Ref" to 14set textAlign of cd fld "Ref" to centerput return &"Copying the text of this journal to a text file." into cd fld "Ref"show cd fld "Ref"lock screenPut short name of this stack &" " &the short date into ReportNamerepeat with i = 1 to number of cdsput (bg fld 2 of cd i) &return &(bg fld 3 of cd i) &return ¬¨&return &(bg fld 1 of cd i) &return &return &return ¬¨after tempend repeatPut bg fld 1 of cd 1 into temp2put temp into bg fld 1set name of bg fld 1 of cd 1 to ReportNameFieldToFile "bkgnd field 1","","MACA"-- FieldToFile ¬©1988 by the Trustees of Dartmouth College.-- FieldToFile fieldDesignation,<full pathname of file>,<creator>set name of bg fld 1 of cd 1 to "Text"put temp2 into bg fld 1 of cd 1play "Harpsichord" "e"hide cd fld "Ref"pop cdset cantmodify of this stack to MtempelsePAlertend ifend PrintJournalon GoHomeglobal leaveStack,OnceOpencleanScreenset cursor to 3put empty into leaveStackput "Opened" into OnceOpenif optionkey() is not down thenvisual zoom ingo first cd of stack "Imitatio Christi"if result() is empty thenelsebeepexit goHomeend ifelseanswer "Go ‚ÄúHome‚Äù or Quit?"  with ¬¨"Home" or "Quit" or "Cancel"if it is "Cancel" thenexit goHomeend ifset cursor to 3put it into leaveStackif it is "Quit" thenif cantmodify of this stack is false thenif the freesize of this stack > 2000 ¬¨and the diskspace > the size of this stack thenAnswer "Straighten sheets and remove stray scraps of paper?" with ¬¨"Compact" or "Next time"If it is "Compact" thengo first cdset rect of cd fld "Ref" to 29,146,434,203put textSize of cd fld "Ref" into tempSput textAlign of cd fld "Ref" into tempAset textSize of cd fld "Ref" to 14set textAlign of cd fld "Ref" to centerPut return &"Removing smudges, aligning sheets, and capping inkwell." ¬¨into cd fld "Ref"lock screenshow cd fld "Ref"unlock screen with dissolvedoMenu "Compact Stack"lock screenhide cd fld "Ref"unlock screen with dissolveset textSize of cd fld "Ref" to tempSset textAlign of cd fld "Ref" to TempAend ifend ifend ifend ifvisual zoom ingo first cd of stack "Imitatio Christi"if result() is empty thenelsevisual dissolve to greyvisual dissolve to greygo stack "Home"end ifend ifend Gohomeon doMenu WhichItemif whichitem is "If Monks Had Macs..." thenanswer ¬¨"       This stack is from the package" &return¬¨&"       ‚ÄúIf Monks Had Macs...‚Äù 2.5.7" &return¬¨&"       ¬©1988,1989  riverTEXT‚Ñ¢"exit domenuend ifif WhichItem is in "Quit HyperCard,New Card,Cut Card,Delete Card," ¬¨&"Find...,Copy Card,Print Card,Print Stack...,Print Report...," ¬¨&"Card Info..." thenif WhichItem is "Quit HyperCard" thenif the freesize of this stack > 2000 ¬¨and the diskspace > the size of this stack thenAnswer "Straighten sheets and remove stray scraps of paper?" with ¬¨"Compact" or "Next time" or "Cancel"if it is "Cancel" thenexit doMenuend ifIf it is "Compact" thenif cantmodify of this stack is false thengo first cdset rect of cd fld "Ref" to 29,146,434,203put textSize of cd fld "Ref" into tempSput textAlign of cd fld "Ref" into tempAset textSize of cd fld "Ref" to 14set textAlign of cd fld "Ref" to centerPut return &"Removing smudges, aligning sheets, and capping inkwell." ¬¨into cd fld "Ref"lock screenshow cd fld "Ref"unlock screen with dissolvedoMenu "Compact Stack"lock screenhide cd fld "Ref"unlock screen with dissolveset textSize of cd fld "Ref" to tempSset textAlign of cd fld "Ref" to TempAelseshow menuBaranswer "The Cantmodify of this stack is set to true," ¬¨&" so compacting is impossible at this time. Next session?"¬¨with "OK"pass doMenuend ifelseif it is "Next time" thenpass domenuend ifend ifpass domenuelsepass doMenuend ifend ifif whichItem is "New Card" thenif cantmodify of this stack is false thenset cursor to 3lock screengo last cd of this bgdoMenu "Copy Card"doMenu "Paste Card"erasePageunlock screen with wipe leftplay "Harpsichord" "a"exit doMenuelsebeepexit doMenuend ifend ifif whichItem is "Copy Card" thenif textFont of bg fld "Text" is  not "marker" thenpass doMenuelsebeepend ifend ifif whichItem is in "Cut Card,Delete Card" thenif textfont of bg fld "Text" is not "marker" thenif cantmodify of this stack is false thencleanScreenif id of this cd is "card id 3048" thenanswer "You mustn't throw away the cover sheet."exit doMenuend ifanswer "Throw this sheet away?" with "Yes" or "No"if it is "Yes" thenif number of cds > 2 thenset cantdelete of this cd to falseset cursor to 3lock screenplay "Harpsichord" "b"pass doMenuelsebeepAnswer "You mustn't throw away the last sheet of this"¬¨&" journal. Erase this entry?" with "Yes" or "No"if it is "Yes" thenerasePageplay "Harpsichord" "a"elseend ifend ifend ifexit doMenuelsebeepanswer "Deprotect the journal, please?" ¬¨with "OK"exit doMenuend ifelsebeepanswer "Remove the password protection, please?" ¬¨with "OK"exit doMenuend ifend ifif WhichItem is in "Print Report...,Print Stack...,Print Card" thenif textFont of bg fld "Text" is not "marker" thenpass doMenuelseanswer return &"You can't print a protected journal." with "Oh."exit doMenuend ifend if-- trap command-F to bring up Find dialog boxif WhichItem is "Find..." thencleanScreenif textFont of bg fld "Text" is not "marker" thensearchAC 1elsebeepend ifelsepass doMenuend ifelsepass doMenuend ifend doMenuon erasePageput empty into bg fld 1put empty into bg fld 4put the abbreviated date into bg fld "Date"put "Sheet #" &number of this cd & " of " &number of cds ¬¨into bg fld "Sheet"end erasePageon returnKeyglobal doFindif visible of msg is false thenif doFind is not empty then --continue searchset cursor to 3do doFindelsepass returnKeyend ifelsepass returnKeyend ifend returnKey-------------------init stack-------------------on openStackcleanScreenif the version < 1.2 thenAnswer "Hypercard version 1.2, or later, is available at your "¬¨&"Apple dealer. Many functions of this stack require the new "¬¨&"features.  Continue?" ¬¨with "Risk It" or "Go Home"if it is "Go Home" thenEjectexit openStackend ifend ifif textFont of bg fld "Text" is "Marker" thenClairvauxmarkerend ifif the short date is not bg fld "ShortDate" of cd 1 thenlock screenput cantmodify of this stack into MTempset cantmodify of this stack to falseget line (random of number of lines of cd fld "Quotes" of cd 1) ¬¨of cd fld "Quotes" of cd 1put "Psalms " &item 1 of it into cd fld "PsalmNumber" of cd 1put item 2 to number of items of it of it into cd fld "Psalmquote"¬¨of cd 1put the short date into bg fld "ShortDate" of cd 1set cantmodify of this stack to MTempunlock screen with dissolveend ifinitAll  --fm HillsAbout " ","If Monks had Macs..."set userLevel to 5end openStackon resumeinitAllpass resumeend resumeon startUpinitAllpass startUpend startUpon initAllglobal whichButton,whichFindButton,textString,doFindglobal Stacks,GVMsgLocput empty into textStringif Stacks is empty thenCheckGlobalsend ifput loc of msg into GVMsgLocget line 1 of bg fld "Hold Globals" of cd 1if it is not empty thenput line 1 of bg fld "Hold Globals" of cd 1 into whichButtonput line 2 of bg fld "Hold Globals" of cd 1 into whichFindButtonput line 3 of bg fld "Hold Globals" of cd 1 into textString-- field remembers Find dialog box settings between stack useselse-- if it doesn't remember, set defaultsput 3 into whichButtonput 3 into whichFindButtonput empty into textStringend ifif textFont of bg fld "Text" is "marker" thenset loc of msg to -1000,-1000put empty into msghide msgset blindTyping to falseend ifend initAllon CheckGlobalsglobal GULevel,GPKeys,GTArrowsglobal GVPatn,GBTyping,GVMsg,GVToolgetHomeInfoput the userLevel into GULevelput the powerKeys Into GPKeysput the textArrows into GTArrowsput the blindTyping into GBTypingput the visible of the msg into GVMsgput the visible of tool window into GVToolput the visible of pattern window into GVPatnend CheckGlobalson closeStackglobal whichButton,whichfindbutton,textString,FType,fieldNameglobal doFind,hits,X1,Y1,X2,Y2,X3,Y3,dir4,currentNOglobal GULevel,GPKeys,GTArrowsglobal GVPatn,GBTyping,GVMsg,GVTool,GVMsgLoccleanScreenhide bg btn "Find Next"if GULevel is empty thenCheckGlobalsend ifset the userLevel to GULevelset the powerKeys to GPKeysset the textArrows to GTArrowsset the blindTyping to GBTypingset the visible of the msg to GVMsgset the visible of tool window to GVToolset the visible of pattern window to GVPatnif char 1 of GVMsgLoc > 0 and char 1 of GVMsgLoc < 9 thenset loc of msg to GVMsgLocelseset loc of msg to 22,300end if-- record find dialog box's most recent settingsput whichButton into line 1 of bg fld "Hold Globals" of cd 1put whichFindButton into line 2 of bg fld "Hold Globals" of cd 1put textString into line 3 of bg fld "Hold Globals" of cd 1if the short date is not bg fld "ShortDate" of cd 1 thenput cantmodify of this stack into MTempset cantmodify of this stack to falseput the short date into bg fld "ShortDate" of cd 1set cantmodify of this stack to MTempend ifput "GVMsgLoc,whichButton,whichfindbutton,textString,FType,fieldName" ¬¨&"doFind,hits,X1,Y1,X2,Y2,X3,Y3,dir4,currentNO" ¬¨into ClearListrepeat with i = 1 to number of items of ClearListdo "put empty into " &item i of clearListend repeat-- if textFont of bg fld "Text" is not "marker" then--  answer "Encrypt Journal?" with "Yes" or "No"--  if it is "Yes" then--    Clairvauxmarker--  end if--end ifaboutend closeStackon Ejectset lockMessages to truevisual wipe right to blackvisual dissolvedoMenu "home"set userLevel to 5end Ejecton Clairvauxmarkerglobal GVMsgLoccleanScreenput script of bg fld "Pword" of cd 1 into Pswdif textFont of bg fld "Text" is "Clairvaux" thenif optionKey() is not down thenanswer "Encrypt Text?" with "No" or "Yes"if it is "No" thenexit Clairvauxmarkerend ifif it is "Yes" thenset cursor to 3ask password "Please type your password below." &return ¬¨&"(If you have forgotten your password, see your owner's manual.)"if it is pswd thenlock screensend mouseUp to bg btn "Can't Modify"hide cd fld "Quotes" of first cdset textFont of bg fld "text" to markerset lockText of bg fld "text" to trueset textFont of cd fld "CardInfo" of cd 1 to markerset loc of msg to -1000,-1000put empty into msghide msgset blindTyping to falseunlock screen with dissolvesend mouseUp to bg btn "Can¬†¬†¬†¬†¬†¬†¬†¬†¬†¬†Modify"elsebeepanswer "That is not the correct password."end ifend ifexit ClairvauxmarkerelseAsk password "What is the current password?"if it is empty thenexit Clairvauxmarkerend ifif it is Pswd thenAsk password "What is the new password?"if it is empty or it is "0" thenbeepexit Clairvauxmarkerend ifput it into Pswd1ask password "Again to confirm your new password choice:"if it is empty or it is "0"thenbeepexit Clairvauxmarkerend ifif it is Pswd1 thenset script of bg fld "Pword" of cd 1 to  Pswd1elsebeepanswer "The entries didn't match. Please try again."end ifelsebeepanswer "That is not the correct current password. Only" ¬¨&" persons with the current password have permission to " ¬¨&"change it." with "Oh."end ifend ifexit Clairvauxmarkerend ifif textFont of bg fld "Text" is "marker" thenglobal tryCounterAsk password "What is the password?"if it is empty thenexit Clairvauxmarkerend ifif it is pswd thenset cursor to 3lock screensend mouseUp to bg btn "Can't Modify"set textFont of bg fld "text" to Clairvauxset lockText of bg fld "text" to falseset textFont of cd fld "CardInfo" of cd 1 to Clairvauxunlock screen with dissolveif char 1 of GVMsgLoc > 0 and char 1 of GVMsgLoc < 9 thenset loc of msg to GVMsgLocelseset loc of msg to 22,300end ifput empty into tryCounterelseput tryCounter + 1 into tryCounterif tryCounter < 3 thenput 3 - tryCounter into triedCounterbeepanswer "Wrong Password. Authorized persons are" &return ¬¨&"requested to please try again. Others are" &return ¬¨&"asked not to pry.         Tries left -- " &triedCounterelseplay "Boing"answer "Wrong password. You must not be authorized to read the journal."¬¨&return &"                                     Click here to go Home." ¬¨with "I'm Sorry"play "Boing"Wait until the sound is "Done"Ejectput empty into tryCounterend ifexit Clairvauxmarkerend ifend ifend Clairvauxmarkeron editif textFont of bg fld "Text" is "Marker" thenelsepass editend ifend edit-- This notice is in the stack script to keep it away from snoops.-- When the Encyptor button is clicked and the text is set in the-- Marker font, the userLevel is set to Browse (no peeking at these-- inst